<template>
	<view class="message-btn-container clear-flex">
		<image src="@/static/image/personal/message@2x.png" style="width: 48rpx; height: 48rpx;"
			class="clear-flex" @click="jumpUrl('/pages/common/message/index')"></image>
			
		<view v-if="messageCount" class="message-btn-dot flex-center-center">{{ messageCount || 0 }}</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				
			}
		},
		computed: {
			messageCount() {
				let { unReadSystemNotifyCount, unReadOrderNotifyCount } = this.messageInfo
				return unReadSystemNotifyCount + unReadOrderNotifyCount
			}
		},
		methods: {}
	}
</script>

<style scoped lang="scss">
	.message-btn {
		&-container {
			position: relative;
			width: 48rpx;
			height: 48rpx;
		}
		
		&-dot {
			position: absolute;
			top: -10rpx;
			right: -20rpx;
			width: 32rpx;
			height: 32rpx;
			font-size: 20rpx;
			color: #ffffff;
			background-color: #FC2642;
			border: 2rpx solid #ffffff;
			border-radius: 32rpx;
			overflow: hidden;
		}
	}
</style>